<?php
$q=$_GET["q"];

$con = mysql_connect('localhost', 'createanalysis', 'createanalysis');
if (!$con)
  {
  die('Could not connect: ' . mysql_error());
  }

mysql_select_db("casl", $con);

$sql="SELECT * FROM cost_analysis WHERE sample_type= '".$q."'";

$result = mysql_query($sql);

echo "<div style='font:13.3px sans-serif;width:30em;border-left:1px solid #808080;border-top:1px solid #808080;border-bottom:1px solid #fff; border-right:1px solid #fff;'>" .
"<div style='background:#fff; overflow:auto;height:7.1em;border-left:1px solid #404040;border-top:1px solid #404040;border-bottom:1px solid #d4d0c8;border-right:1px solid #d4d0c8;'>";
$label = 1;
while($row = mysql_fetch_array($result)){
echo "<label for='$label' style='padding-right:3px;display:block;'><input name='checkbox". $_GET["value"]."[]' value='1' type='checkbox' id='checkbox". $_GET["value"]."' onclick='highlight_div(this);'>" .
		$row['analysis_type'] . "</label>";
		//echo $label;
		$label++;
}
echo"</div>" . "</div>";

mysql_close($con);

?>